package vo

// 新增角色结构体
type CreateRoleRequest struct {
	Name   string `json:"name" form:"name" validate:"required,min=1,max=20"`
	Code   string `json:"code" form:"code" validate:"required,min=1,max=20"`
	Remark string `json:"remark" form:"remark" validate:"min=0,max=100"`
	Status uint   `json:"status" form:"status" validate:"oneof=1 2"`
	Sort   uint   `json:"sort" form:"sort" validate:"gte=1,lte=9999"`
}

// 更新角色结构体
type UpdateRoleRequest struct {
	ID     uint   `json:"ID" form:"ID"`
	Name   string `json:"name" form:"name" validate:"required,min=1,max=20"`
	Code   string `json:"code" form:"code" validate:"required,min=1,max=20"`
	Remark string `json:"remark" form:"remark" validate:"min=0,max=100"`
	Status uint   `json:"status" form:"status" validate:"oneof=1 2"`
	Sort   uint   `json:"sort" form:"sort" validate:"gte=1,lte=9999"`
}

// 获取用户角色结构体
type RoleListRequest struct {
	Name   string `json:"name" form:"name"`
	Code   string `json:"code" form:"code"`
	Status uint   `json:"status" form:"status"`
	Pagination
}

// 批量删除角色结构体
type DeleteRoleRequest struct {
	RoleIds []uint `json:"roleIds" form:"roleIds"`
}

// 更新角色的权限菜单
type UpdateRoleMenusRequest struct {
	MenuIds []uint `json:"menuIds" form:"menuIds"`
}

// 更新角色的权限接口
type UpdateRoleApisRequest struct {
	ApisIds []uint `json:"apisIds" form:"apisIds"`
}
